package saeildamil.Ch18.thread;

import javax.swing.JOptionPane;

public class MultiThreadEx01 {
	public static void main(String[] args) {
		//0~9까지 쓰레드로 실행
		DigitThreadEx thread1 = new DigitThreadEx();
		DigitThreadEx thread2 = new DigitThreadEx();
		AlphabetThreadEx thread3 = new AlphabetThreadEx();
		
		thread1.start(); // run()가 호출 thread로 동작
		thread2.start();
		thread3.start();
	/*	thread.run(); 	// run() 메소드가 실행하고 thread가 동작하지 않는다.*/		
		
		String message = "main thread 종료";
		JOptionPane.showMessageDialog(null, message);
		
	}

}
